home *** CD-ROM | disk | FTP | other *** search
- @ECHO OFF
- REM This is DUPFILE.BAT
- IF %1!==! GOTO OOPS
- ECHO Checking files . . .
- FOR %%A IN (*.*) DO IF EXIST %1\%%A ECHO %%A is in both places.
- PAUSE
- FOR %%A IN (*.*) DO IF NOT EXIST %1\%%A ECHO %%A is NOT in %1
- GOTO END
- :OOPS
- ECHO This searches for duplicate filenames
- ECHO in two disks or directories.
- ECHO First, make sure %0.BAT is in a directory
- ECHO that your PATH knows about. Then log into
- ECHO one of the directories or disks that
- ECHO you want to examine, and enter the name
- ECHO of the other directory or disk after %0.
- ECHO So to see a list of all filenames
- ECHO that are in both C:\DOS and B:,
- ECHO log into C:\DOS and type:
- ECHO.
- ECHO %0 B:
- ECHO.
- ECHO Or log into B: and type:
- ECHO.
- ECHO %0 C:\DOS
- ECHO.
- ECHO To check 2 subdirectories called \DOS4 and \DOS5,
- ECHO log into \DOS4 and type:
- ECHO.
- ECHO %0 \DOS5
- ECHO.
- ECHO Or log into \DOS5 and type:
- ECHO.
- ECHO %0 \DOS4
- ECHO.
- :END
-